// 商品管理
import request from '@/utils/request'

export function list(data) {
  return request({
    url: '/api/goods/list',
    method: 'post',
    data: data
  })
}

export function create(data) {
  return request({
    url: '/api/goods/create',
    method: 'post',
    data: data
  })
}

export function update(data) {
  return request({
    url: '/api/goods/update',
    method: 'post',
    data: data
  })
}

export function delete_(data) {
  return request({
    url: '/api/goods/delete',
    method: 'post',
    data: data
  })
}

// 导入商品数据
export function import_(data) {
  return request({
    url: '/api/goods/import',
    method: 'post',
    data: data
  })
}

// 批量更新
export function batchUpdate(data) {
  return request({
    url: '/api/goods/batch_update',
    method: 'post',
    data: data
  })
}
